package com.kly.sc.api.application.controller.config.request;

import com.kly.user.dto.UserInfoDto;
import lombok.Builder;
import lombok.Data;

@Data
@Builder
public class CustomerServiceVo {
    private String iocn;
    private Integer code;
    private String name;
    private String userCode;
    private String email;

    public static CustomerServiceVo toVo(UserInfoDto dto, Integer code) {
        return CustomerServiceVo.builder().code(code).iocn(dto.getAvatarUrl())
                .name(dto.getNickName()).userCode(dto.getUserCode()).email(dto.getEmail()).build();
    }
}
